import request from '@/utils/request'

// 查询路况列表
export function listRoad(query) {
  return request({
    url: '/road/list',
    method: 'get',
    params: query
  })
}

// 查询路况详细
export function getRoad(id) {
  return request({
    url: '/road/' + id,
    method: 'get'
  })
}

// 新增路况
export function addRoad(data) {
  return request({
    url: '/road',
    method: 'post',
    data: data
  })
}

// 修改路况
export function updateRoad(data) {
  return request({
    url: '/road',
    method: 'put',
    data: data
  })
}

// 删除路况
export function delRoad(id) {
  return request({
    url: '/road/' + id,
    method: 'delete'
  })
}
